package cn.learn.proto;

import cn.learn.server.Record;
import cn.learn.server.jute.InputArchive;
import cn.learn.server.jute.OutputArchive;

import java.io.IOException;

public class CreateRequest implements Record {

    private String path;
    private byte[] data;

    @Override
    public void serialize(OutputArchive outputArchive, String tag) throws IOException {

    }

    @Override
    public void deserialize(InputArchive a_, String tag) throws IOException {
        a_.startRecord(tag);
        path=a_.readString("path");
        data=a_.readBuffer("data");
    }

    public String getPath() {
        return path;
    }

    public void setPath(String path) {
        this.path = path;
    }

    public byte[] getData() {
        return data;
    }

    public void setData(byte[] data) {
        this.data = data;
    }
}
